<?php
namespace HelloAdmin\Controller;
use Think\Controller;
class SiteController extends CommonController {
    public function index(){

        //var_dump(C('AUTH_CONFIG'));

        $this->display('menu');
    }

    //网站基础设置
    public function basic(){

        $this->display('Index/siteBasic');
    }

    public function logo(){

        $this->display('Index/siteLogo');
    }

    /**
     * 模板列表
     */
    public function tplList(){


        $this->display();
    }

    /**
     * 系统模块
     */
    public function sysController(){


        $this->display();
    }

    /**
     * 导航菜单
     */
    public function headerMenu(){

        $data = D('Menus')->select();
        $this->assign('data',$data);
        $this->display();
    }

    /**
     * 微信token 刷新
     */
    public function refreshAccessToken(){
        $access_token = S('access_token');
        if(empty($access_token)){
            exit('SUCCESS');
        }
        S('access_token',null);
        $access_token = S('access_token');
        if(empty($access_token)){
            exit('SUCCESS');
        }
        exit('ERROR');
    }
}